import Vue from "vue";
import App from "./App.vue";
import router from "./router";
import store from "./store";

import "lib-flexible";
import "@/assets/font/iconfont.css"

import "./permission";
import "@/assets/styles/style.scss";

import { cloneDeep } from "lodash";
Vue.prototype.$cloneDeep = cloneDeep;
import Utils from "@/utils";
Vue.use(Utils);
import http from "@/utils/axios";
Vue.prototype.$http = http;
import types from "@/store/actionTypes";
Vue.prototype.$types = types;
import setting from "./setting";
Vue.prototype.$setting = setting;
import dictUtils from "@/utils/dict"
Vue.prototype.$dictUtils = dictUtils;

Vue.prototype.$window = window;

import VConsole from "vconsole";
if (process.env.NODE_ENV !== "production") {
  // new VConsole()
}

import Vant from "vant";
import "vant/lib/index.css";
Vue.use(Vant);
let loading = Vue.prototype.$toast.loading;
Vue.prototype.$toast.loading = (params) => {
  return params.duration ? loading(params) : loading({ ...params, duration: 0 });
};
Vue.config.productionTip = false;

new Vue({
    router,
    store,
    render: (h) => h(App),
}).$mount("#app");